Functions to calculate the mean, variance, skewness, kurtosis and mode of a specific normal inverse Gaussian distribution.
nigMean(mu = 0, delta = 1, alpha = 1, beta = 0,
param = c(mu, delta, alpha, beta))
nigVar(mu = 0, delta = 1, alpha = 1, beta = 0,
param = c(mu, delta, alpha, beta))
nigSkew(mu = 0, delta = 1, alpha = 1, beta = 0,
param = c(mu, delta, alpha, beta))
nigKurt(mu = 0, delta = 1, alpha = 1, beta = 0,
param = c(mu, delta, alpha, beta))
nigMode(mu = 0, delta = 1, alpha = 1, beta = 0,
param = c(mu, delta, alpha, beta))
\(\mu\) is the location parameter. By default this is set to 0.
\(\delta\) is the scale parameter of the distribution. A default value of 1 has been set.
\(\alpha\) is the tail parameter, with a default value of 1.
\(\beta\) is the skewness parameter, by default this is 0.
Parameter vector of the normal inverse Gaussian distribution.
nigMean
gives the mean of the normal inverse Gaussian distribution,
nigVar
the variance, nigSkew
the skewness,
nigKurt
the kurtosis and nigMode
the mode.
Note that the kurtosis is the standardised fourth cumulant or what is sometimes called the kurtosis excess. (See http://mathworld.wolfram.com/Kurtosis.html for a discussion.)
The parameterization of the normal inverse Gaussian distribution used
for this and other components of the GeneralizedHyperbolic
package is the \((\alpha, \beta)\) one. See
hyperbChangePars
to transfer between parameterizations.
The mean, variance, skewness, kurtosis and mode for the normal inverse
Gaussian distribution can be obtained from the functions for the
generalized hyperbolic distribution as special cases (i.e.,
\(\lambda\) = -1/2). Likewise other moments can be obtained
from the function ghypMom
which implements a recursive
method to moments of any desired order.
The proper formulae for the mean, variance and skewness of the normal inverse Gaussian distribution can be found in Paolella, Marc S. (2007), Chapter 9, p325.
Paolella, Marc S. (2007) Intermediate Probability: A Computational Approach, Chichester: Wiley
dnig
, hyperbChangePars
,
besselK
, ghypMom
, ghypMean
,
ghypVar
, ghypSkew
, ghypKurt
# NOT RUN {
param <- c(2, 2, 2, 1)
nigMean(param = param)
nigVar(param = param)
nigSkew(param = param)
nigKurt(param = param)
nigMode(param = param)
# }
Run the code above in your browser using DataLab